import { BasicColumn } from '/@/components/Table';
import { FormSchema } from '/@/components/Table';

/**
 * 检测能力库-查询字段
 */
export const searchFormSchema: FormSchema[] = [
  {
    label: '检测项',
    field: 'keyword',
    component: 'JInput',
    colProps: { span: 6 },
  },
  {
    label: '检测方法号',
    field: 'keyword',
    component: 'JInput',
    colProps: { span: 6 },
  },
];
/**
 * 检测能力库-表格数据
 */
export const columns: BasicColumn[] = [
  {
    title: '序号',
    dataIndex: '',
    key: 'rowIndex',
    width: 60,
    align: 'center',
    customRender: ({ index }) => {
      return parseInt(index) + 1;
    },
  },
  {
    title: '检测项',
    dataIndex: 'name', //字段不对
    width: 120,
  },
  {
    title: '检测方法号',
    dataIndex: 'testStdNo',
    width: 100,
  },
  {
    title: '检测方法名称',
    dataIndex: 'testStdName',
    width: 120,
  },
  {
    title: '实验室',
    dataIndex: 'labName',
    width: 80,
  },
  {
    title: '技术中心',
    dataIndex: 'orgName',
    width: 100,
  },
  {
    title: '检测类型',
    dataIndex: 'catName',
    width: 100,
  },
];
/**
 * 风险信息库-表单数据
 */
export const formSchema: FormSchema[] = [
  {
    label: '检测项',
    field: 'name',
    component: 'Input',
  },
  {
    label: '检测方法号',
    field: 'testStdNo',
    component: 'Input',
  },
  {
    label: '检测方法名称',
    field: 'testStdName',
    component: 'Input',
  },
  {
    label: '实验室',
    field: 'labName',
    component: 'Input',
  },
  {
    label: '技术中心',
    field: 'orgName',
    component: 'Input',
  },
  {
    label: '检测类型',
    field: 'catName',
    component: 'Input',
  },
];
